?><?
function parse_tag_params($tag){
  $token=strtok($tag,"=\"");
  $tag_params=array();
  do{
    if($idx++%2==0){
      $name=trim($token);
    }else{
      $tag_params[$name]=trim($token);
    }
  }while($token=strtok("=\""));
  return $tag_params;
}